import React from 'react';

import Paper from 'material-ui/Paper';

import AppBarYz from './AppBarYz';
import DrawerYz from './DrawerYz';
import LoginYz from './LoginYz';

export const FrameYz = ({ open, children, toggleDrawer }) => (
  <div>
    <LoginYz show="flex" />
  	<DrawerYz open={open} />
  	<Paper 
  	  style={(open)? {marginLeft: 200}: {marginLeft: 0}} 
  	  zDepth={0} 
  	>
  	  <AppBarYz open={open} toggleDrawer={toggleDrawer} />
  	  <div>
  	    {children}
  	  </div>
  	</Paper>
  </div>
);

FrameYz.propTypes = {
	open: React.PropTypes.bool.isRequired,
	children: React.PropTypes.element.isRequired
}

export default FrameYz;